import java.util.GregorianCalendar;
import java.util.Random;
import java.util.Scanner;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: 38917
 * Date: 2025-02-13
 * Time: 23:22
 */
public class guess {
    public static void Guess(){
        Scanner scanner = new Scanner(System.in);
        System.out.println("请输入数字");
        Random random = new Random();
        int sum1 = 0;
        int sum2 = random.nextInt(100) + 1;
        while (sum1 != sum2){
            sum1 = scanner.nextInt();
            if (sum1 < sum2) System.out.println("猜小了");
            if (sum1 > sum2) System.out.println("猜大了");
        }
        System.out.println("猜对了");
    }

    public static void main(String[] args) {
        Guess();
    }
}
